Graphical modeling and graphical programming environments allow users to design, simulate and analyze graphical structures that represent systems, such as dynamic systems. A graphical structure representing a system may implement time-dependent or event-dependent mathematical relationships among its inputs, states and outputs. Blocks, described in more detail below, are one type of graphical structure. The blocks may describe computations performed on application-specific computational hardware, such as a computer, microcontroller, Field Programmable Gate Array (FPGA), or custom hardware. The blocks may be used to produce deployable software systems, or to produce descriptions of hardware systems that can mimic the behavior of either the entire model or portions of the model (referred to herein as ‘code generation’). The term ‘block’ will hereafter be used generally to refer to graphical structures.
Graphical structures may be part of a block diagram model which may contain blocks and lines. The lines in a block diagram model may carry information, describe dependencies, or define relationships between the blocks. The lines may also have operations or mathematics associated with them. The blocks in a block diagram model may be dynamic system elements that define operations (generally referred to as block methods), represent mathematical equations, and/or contain state information. Methods defined by a block may include output operations and update operations. Output operations may calculate an output of a block, and update operations may update a state of a block.
A block in a block diagram model may be enabled when an enabling condition is satisfied, or disabled when the enabling condition is not satisfied. Conventionally, when a block is enabled, both the output and update operations associated with the block are executed to produce an output and to update a state of the block, respectively. In contrast, when a block is disabled, neither the output operation nor the update operation associated with the block is executed.